Release 10.1A: OpenEdge Development:
Progress 4GL Reference
Progress.Lang.Object class
Progress.Lang.Object provides a common set of data members and methods that all classes inherit. This set of data members and methods let you write generic code to use with any user-defined class.
Progress.Lang.Object is the ultimate super class for all user-defined classes that do not explicitly inherit a super class using the INHERITS phrase.
You typically use this class to define a variable or parameter to represent more than one user-defined class type. For example:
Inherits
This class does not inherit a super class.
Implements
This class does not implement an interface.
Data
membersThis class contains the following data members:
NEXT-SIBLING AS Progress.Lang.ObjectThe object reference for the next class object instance in the list of instances created in the current OpenEdge session. The value of this data member is available after obtaining a valid object reference (for example, by using the SESSION:FIRST-OBJECT attribute to obtain the object reference for the first class object instance in the list). If there are no class object instances in the current session, or you have gone past the last class object instance in the list, this attribute returns the Unknown value (
?).Once your position in the list is established, you can use the NEXT-SIBLING and PREV-SIBLING data members to walk the list of class object instances.
To check the validity of an object reference, use the VALID-OBJECT function.
This data member is read-only.
PREV-SIBLING AS Progress.Lang.ObjectThe object reference for the previous class object instance in the list of instances created in the current OpenEdge session. The value of this data member is available after obtaining a valid object reference (for example, by using the SESSION:LAST-OBJECT attribute to obtain the object reference for the last class object instance in the list). If there are no class object instances in the current session, or you have gone past the first class object instance in the list, this attribute returns the Unknown value (
?).Once your position in the list is established, you can use the NEXT-SIBLING and PREV-SIBLING data members to walk the list of class object instances.
To check the validity of an object reference, use the VALID-OBJECT function.
This data member is read-only.
Methods
This class contains the following methods:
CONSTRUCTOR PUBLIC Object ( )Constructs an object instance of this class. Since this constructor method takes no parameters, Progress automatically invokes it when creating a subclass of this super class.
METHOD PUBLIC Progress.Lang.Object Clone ( )Creates a copy of an object instance and returns an object reference for the copy.
This method has no default behavior. You must override this method in a user-defined class. If you invoke this method without overriding it, Progress generates an error message and returns the Unknown value (
?).
METHOD PUBLIC LOGICAL Equals (OtherObjAS Progress.Lang.Object )Compares the object reference for this class object instance to another object reference, where
OtherObjis the other object reference with which to compare. If the object references are equivalent (that is, the data members of the two object instances are the same, or the two object references are referencing the same object instance), this method returns TRUE. Otherwise, it returns FALSE.This method has no default behavior. You must override this method in a user-defined class. If you invoke this method without overriding it, Progress generates an error message and returns the Unknown value (
?).
METHOD PUBLIC Progress.Lang.Class GetClass ( )Returns the object reference for the Progress.Lang.Class object instance associated with the current user-defined class object instance.
METHOD PUBLIC CHARACTER ToString ( )This method returns the class name of the object instance followed by a unique object identifier.
You typically override this method in a user-defined class to provide additional contextual information.
Note: This method is used by some Progress string functions and statements, such as the QUOTER and STRING functions and the MESSAGE and PUT statements.
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |